package org.example.service;

import org.example.holder.PrototypeDataHolder;
import org.example.holder.RequestDataHolder;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * 服务类 - 演示不同作用域Bean的注入和使用
 */
@Service
public class MyService {
    @Autowired
    private PrototypeDataHolder prototypeDataHolder;

    @Autowired
    private RequestDataHolder requestDataHolder;

    public PrototypeDataHolder getPrototypeDataHolder() {
        return prototypeDataHolder;
    }

    public RequestDataHolder getRequestDataHolder() {
        return requestDataHolder;
    }
    

} 